Announcement

Collapse
No announcement yet.

Notificación persistente de IBus sobre `QT_IM_MODULE`/`GTK_IM_MODULE` (Kubuntu 25.04, Plasma 6, Wayland)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [System] Notificación persistente de IBus sobre `QT_IM_MODULE`/`GTK_IM_MODULE` (Kubuntu 25.04, Plasma 6, Wayland)

    **Asunto:** Notificación persistente de IBus sobre `QT_IM_MODULE`/`GTK_IM_MODULE` tras habilitar IBus Wayland (Kubuntu 25.04, Plasma 6, Wayland)

    **Entorno:**
    * **Sistema Operativo:** Kubuntu 25.04 (Plucky Puffin)
    * **Entorno de Escritorio:** KDE Plasma 6.3.4
    * **Servidor Gráfico:** Wayland
    * **Herramienta de Configuración de Método de Entrada:** `im-config` versión 0.57-2

    **Descripción del Problema:**
    Al iniciar sesión por primera vez en una sesión Wayland de KDE Plasma en Kubuntu 25.04, se recibe una notificación de IBus que recomienda la configuración del método de entrada para Wayland. El texto exacto de esta primera notificación es:

    "IBus debe ser llamado desde la sesión de escritorio en Wayland. Para KDE, puede ejecutar la utilidad «systemsettings5» e ir a la sección «Dispositivos de entrada» -> «Teclado virtual» y seleccionar el icono «IBus Wayland» y pulsar el botón «Aplicar» para configurar IBus en Wayland. Para otras sesiones de escritorio, puede copiar la línea «Exec=» en el archivo org.freedesktop.IBus.Panel.Wayland.Gtk3.desktop a un archivo de configuración de la sesión. Consulte cada documento sobre la configuración del «método de entrada de Wayland». Antes de configurar el «método de entrada de Wayland», debe asegurarse de que las variables de entorno QT_IM_MODULE y GTK_IM_MODULE están desactivadas en la sesión de escritorio. "

    Después de seguir las instrucciones de esta primera notificación (específicamente, habilitar "IBus Wayland" en la configuración de "Teclado virtual" de KDE y reiniciar el sistema), comenzó a aparecer una segunda notificación persistente de IBus. Esta segunda notificación, que aparece al inicio de sesión y al reanudar el sistema, indica:

    "Desactive las variables de entorno QT_IM_MODULE y GTK_IM_MODULE y «ibus-daemon --panel disable» debe ejecutarse como un proceso hijo del componente ibus-ui-gtk3."


    **Comportamiento Observado:**
    1. (Esta sección describe el comportamiento observado *tras* la segunda notificación, que fue el foco de la depuración). Las variables de entorno `QT_IM_MODULE` y `GTK_IM_MODULE` están configuradas con el valor `ibus` en la sesión de usuario (verificado mediante `echo $QT_IM_MODULE` y `echo $GTK_IM_MODULE`).
    2. Estas variables no se encuentran configuradas explícitamente en archivos de configuración de usuario comunes como `~/.profile` o `~/.bashrc`.
    3. El paquete `imsettings-plasma` no está instalado en el sistema.
    4. La herramienta gráfica `im-config` (ejecutada desde terminal) muestra una interfaz no interactiva que resume la configuración automática del método de entrada, indicando que la "Elección automática normal" y "actual" es `ibus`, basada en el modo `auto` de `/etc/default/im-config`.
    5. Al intentar aceptar en la GUI de `im-config`, un diálogo adicional pregunta sobre guardar configuración de usuario explícita; se seleccionó "No" para evitar la creación de un archivo de usuario conflictivo.


    **Causa Raíz:**
    La utilidad `im-config`, configurada en su modo predeterminado `IM_CONFIG_DEFAULT_MODE=auto` mediante el archivo `/etc/default/im-config`, selecciona automáticamente `ibus` y establece las variables de entorno `QT_IM_MODULE` y `GTK_IM_MODULE`. Esta acción, si bien puede ser esperada en entornos X11 o configuraciones antiguas, entra en conflicto con la integración moderna de IBus en una sesión Wayland gestionada por KDE Plasma 6, donde el entorno de escritorio debería manejar la activación de IBus directamente. Este conflicto, activado al seleccionar explícitamente "IBus Wayland" en Plasma (lo que hace que Plasma espere controlar IBus), genera la segunda notificación de IBus.


    **Solución Implementada:**
    La solución consistió en modificar el archivo de configuración del sistema de `im-config` para evitar que establezca automáticamente el método de entrada y sus variables asociadas, delegando esta tarea completamente al entorno de escritorio.

    1. Se editó el archivo `/etc/default/im-config` con permisos de superusuario:

    sudo kate /etc/default/im-config


    2. Se cambió el modo de operación comentando la línea `IM_CONFIG_DEFAULT_MODE=auto` y descomentando la línea `IM_CONFIG_DEFAULT_MODE=none`.

    -#IM_CONFIG_DEFAULT_MODE=auto
    +IM_CONFIG_DEFAULT_MODE=none

    El modo `none` evita que `im-config` inicie o configure el método de entrada, permitiendo que Plasma lo gestione directamente.


    3. Se guardaron los cambios y se cerró el editor.


    4. Se cerró la sesión de usuario y se volvió a iniciar para aplicar la modificación.


    **Verificación de la Solución:**
    Tras aplicar los cambios y reiniciar la sesión, la segunda notificación persistente de IBus ya no aparece. La verificación mediante `echo $QT_IM_MODULE` y `echo $GTK_IM_MODULE` confirma que estas variables están ahora vacías, validando que `im-config` ha dejado de establecerlas y que la gestión de IBus en Wayland funciona correctamente sin el conflicto.​

    #2
    Translation:

    Topic: Persistent IBus notification about `QT_IM_MODULE`/`GTK_IM_MODULE` (Kubuntu 25.04, Plasma 6, Wayland)​


    **Subject:** Persistent IBus notification about `QT_IM_MODULE`/`GTK_IM_MODULE` after enabling IBus Wayland (Kubuntu 25.04, Plasma 6, Wayland) **Environment:** * **Operating System:** Kubuntu 25.04 (Plucky Puffin) * **Desktop Environment:** KDE Plasma 6.3.4 * **Graphic Server:** Wayland * **Input Method Configuration Tool:** `im-config` version 0.57-2

    **Problem Description:** When logging into a KDE Plasma Wayland session for the first time on Kubuntu 25.04, you receive an IBus notification recommending setting your input method to Wayland. The exact text of this first notification is: "IBus must be called from the desktop session on Wayland. For KDE, you can run the "systemsettings5" utility, go to the "Input Devices" -> "Virtual Keyboard" section, select the "IBus Wayland" icon, and press the "Apply" button to configure IBus on Wayland. For other desktop sessions, you can copy the "Exec=" line from the org.freedesktop.IBus.Panel.Wayland.Gtk3.desktop file to a session configuration file. Refer to each document on configuring the "Wayland input method." Before configuring the "Wayland input method," you must ensure that the QT_IM_MODULE and GTK_IM_MODULE environment variables are disabled in the desktop session. "

    After following the instructions in this first notification (specifically, enabling "IBus Wayland" in the KDE "Virtual Keyboard" settings and restarting the system), a second persistent notification from IBus began appearing. This second notification, which appears upon login and restart, states: "Disable the QT_IM_MODULE and GTK_IM_MODULE environment variables, and 'ibus-daemon --panel disable' must run as a child process of the ibus-ui-gtk3 component."


    **Observed Behavior:** 1. (This section describes the behavior observed *after* the second notification, which was the focus of the debug.) The environment variables `QT_IM_MODULE` and `GTK_IM_MODULE` are set to `ibus` in the user session (verified by `echo $QT_IM_MODULE` and `echo $GTK_IM_MODULE`). 2. These variables are not explicitly set in common user configuration files such as `~/.profile` or `~/.bashrc`. 3. The `imsettings-plasma` package is not installed on the system. 4. The `im-config` graphical tool (run from a terminal) displays a non-interactive interface summarizing the input method autoconfiguration, indicating that the "normal" and "current" autochoice is `ibus`, based on the `auto` mode in `/etc/default/im-config`. 5. When attempting to access the `im-config` GUI, an additional dialog asks about saving explicit user settings; "No" was selected to avoid creating a conflicting user file.


    **Root Cause:** The `im-config` utility, configured in its default mode `IM_CONFIG_DEFAULT_MODE=auto` via the `/etc/default/im-config` file, automatically selects `ibus` and sets the `QT_IM_MODULE` and `GTK_IM_MODULE` environment variables. This action, while expected in X11 environments or older setups, conflicts with modern IBus integration in a Wayland session managed by KDE Plasma 6, where the desktop environment should handle IBus activation directly. This conflict, triggered by explicitly selecting "IBus Wayland" in Plasma (which causes Plasma to expect to control IBus), generates the second IBus notification.


    **Implemented Solution:** The solution consisted of modifying the `im-config` system configuration file to prevent it from automatically setting the input method and its associated variables, delegating this task entirely to the desktop environment. 1. Edited the `/etc/default/im-config` file with superuser permissions: sudo kate /etc/default/im-config 2. Changed the operating mode by commenting out the `IM_CONFIG_DEFAULT_MODE=auto` line and uncommenting the `IM_CONFIG_DEFAULT_MODE=none` line.

    -#IM_CONFIG_DEFAULT_MODE=auto
    +IM_CONFIG_DEFAULT_MODE=none


    The `none` mode prevents `im-config` from initializing or configuring the input method, allowing Plasma to manage it directly. 3. The changes were saved and the editor was closed. 4. The user session was logged out and logged back in to apply the changes.


    **Verification of the Solution:** After applying the changes and restarting the session, the second persistent IBus notification no longer appears. Verification using `echo $QT_IM_MODULE` and `echo $GTK_IM_MODULE` confirms that these variables are now empty, validating that `im-config` has stopped setting them and that IBus management in Wayland works correctly without the conflict.

    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment

    Working...
    X